package javango.core;

import com.google.inject.Inject;
import com.google.inject.Injector;

public class UrlFactory {

	protected Injector injector;
	
	@Inject
	public UrlFactory(Injector injector) {
		super();
		this.injector = injector;
	}

	public RegUrl regUrl(String pattern, Class<?> clazz, String methodName) {
		return new RegUrl(injector, pattern, clazz, methodName);
	}
	
	public SubappUrl subappUrl(String pattern, Class<? extends Urls> urlsClass) {
		return new SubappUrl(injector, pattern, urlsClass);
	}
	
	public SimpleUrl simpleUrl(String pattern, Class<?> clazz, String methodName) {
		return new SimpleUrl(this, pattern, clazz, methodName);
	}
}
